import java.util.Scanner;

public class Test7 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        System.out.println("请输入学生信息（格式：学号:姓名:分数）：");
        String input = scanner.nextLine();
        scanner.close();
        String[] parts = input.split(":");
        if (parts.length != 3) {
            System.out.println("输入格式错误，请使用 学号:姓名:分数 格式");
            return;
        }
        String id = parts[0];
        String name = parts[1];
        int score;
        try {
            score = Integer.parseInt(parts[2]);
        } catch (NumberFormatException e) {
            System.out.println("分数格式错误，必须是整数");
            return;
        }
        Student s = new Student(id, name, score);
        System.out.println(s);
    }
}